<script type="text/javascript" src="<?php echo base_url()?>themes/back/js/ckeditor/ckeditor.js"></script>
<script type="text/javascript" src="<?php echo base_url()?>themes/back/js/ckfinder/ckfinder.js"></script>
		<div class="row">
		    <div class="col-xs-7">
		        <div class="box box-primary">
		            <div class="box-header">
		                <h3 class="box-title">Tambah Data Layanan</h3>
		            </div><!-- /.box-header -->
		            <?php echo form_open_multipart('content_testimoni/save', array('role' => 'form', 'id' => 'form'));?>
		            <div class="box-body">				        
                  <!-- text input -->
                  <div class="form-group">
                  	<label>Nama</label>
	                  <input class="form-control input-sm" name="nama" type="text" placeholder="Nama">
									</div>
									<div class="form-group">
                  	<label>Pekerjaan</label>
	                  <input class="form-control input-sm" name="pekerjaan" type="text" placeholder="Pekerjaan">
									</div>
	                <div class="form-group">
	                  <label>Foto</label>
										<input type="file" name="gambar" id="gambar">
										<p class="help-block">Disarankan menggunakan foto ukuran 200 x 200 pixel</p>
					   			</div>
					   			<div class="form-group">
	                  <label>Testimoni</label>
										<textarea class="form-control" rows="3" id="testimoni" name="testimoni" placeholder="Testimoni"></textarea>
									</div>
		            </div>		                   
                <div class="box-footer">
                     <button type="submit" class="btn btn-sm btn-primary btn-flat"><i class="fa fa-floppy-o"></i> Simpan</button>
                </div>
								<?php echo form_close();?>
		        </div><!-- /.box -->                            
		    </div>
		</div>

		<script>
			var editor=CKEDITOR.replace( 'testimoni',{								
			toolbar :[[ 'Bold', 'Italic', '-', 'NumberedList', 'BulletedList', '-', 'Link', 'Unlink','Image' ],	[ 'Styles','Format','Font','FontSize' ],
						['JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'],
						[ 'UIColor','-','Source' ]]		
				});
			CKFinder.setupCKEditor( editor, '<?php echo base_url()?>themes/back/js/ckfinder/' ) ;
			$("#form").validate({
				rules: {
					nama: {
						required: true
					},
					pekerjaan: {
						required: true
					},
					testimoni: {
						required: true,
						minlength: 10
					}
				}
			});
		</script>